# encoding=utf8

"""
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements.  See the NOTICE file
distributed with this work for additional information
regarding copyright ownership.  The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License.  You may obtain a copy of the License at
    http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
"""

import os
from lib.resource_management import *
import ast
import socket
from lib.resource_management.libraries.script.script import Script

config = Script.get_config()

# 源码包下载地址
hue_download_url = config['configurations']['hue-ambari-config']['hue.package.download.url']

# HDP配置信息
hdp_base_dir = ''

# Hue用户与组信息
hue_user = config['configurations']['hue-env']['hue_user']
hue_group = config['configurations']['hue-env']['hue_group']

# Hue目录信息
hue_base_dir = ''
hue_pid_dir = config['configurations']['hue-env']['hue_pid_dir']
hue_log_dir = config['configurations']['hue-env']['hue_log_dir']
hue_bin_dir = '/' + hue_base_dir.strip('/') + '''/build/env/bin/'''
hue_conf_dir = '/' + hue_base_dir.strip('/') + '''/desktop/conf/'''